<template>
  <div class="layout-container">
    <!-- 左侧导航栏 -->
    <el-aside width="200px">
      <el-menu
        :default-openeds="['1']"
        :unique-opened="true"
        router
        background-color="#545c64"
        text-color="#fff"
        active-text-color="#ffd04b"
      >
        <el-submenu index="1">
          <template slot="title">
            <i class="el-icon-menu"></i>
            <span>汽车修理后台管理</span>
          </template>
          <el-menu-item index="/shoppingordermanage">商城订单管理</el-menu-item>
          <el-menu-item index="/maintorder">维修订单管理</el-menu-item>
          <el-menu-item index="/addressmanage">收货地址管理</el-menu-item>
          <el-menu-item index="/adminmanage">登陆人管理</el-menu-item>
          <el-menu-item index="/goodsmanage">商品管理</el-menu-item>
        </el-submenu>
      </el-menu>
    </el-aside>
    <!-- 右侧内容区域 -->
    <el-main></el-main>
  </div>
</template>

<script>
import axios from "axios";

export default {
  name: "LayoutPage",
  data() {
    return {
      tableData: [],
    }
  },
  methods: {
    findShoppingOrder() {
      axios.post("/shoppingorder/findShoppingOrder").then(res => {
        this.tableData = res.data.data.list;
      })
    }
  },
  created() {
    this.findShoppingOrder();
  }
};
</script>

<style scoped>
.layout-container {
  display: flex;
  height: 100vh;
}

.el-aside {
  background-color: #545c64;
}

.el-main {
  flex: 1;
  padding: 20px;
}
</style>
